package com.example.beans;

import java.sql.Timestamp;

/**
 *  
 *  * @projectName flink-1.13.2-study
 *  * @title     UrlViewCount   
 *  * @package    com.example.beans  
 *  * @description    定义了一个 POJO 类 UrlViewCount 来表示聚合输出结果的 数据类型，包含了 url、浏览量以及窗口的起始结束时间  
 *  * @author hjx     
 *  * @date   2022-3-29 9:30  
 *  * @version V1.0.0
 *  * @copyright 2022 ty
 *  
 */
public class UrlViewCount {
    public String url;
    public Long count;
    public Long windowStart;
    public Long windowEnd;

    public UrlViewCount() {
    }

    public UrlViewCount(String url, Long count, Long windowStart, Long windowEnd) {
        this.url = url;
        this.count = count;
        this.windowStart = windowStart;
        this.windowEnd = windowEnd;
    }

    @Override
    public String toString() {
        return "UrlViewCount{" +
                "url='" + url + '\'' +
                ", count=" + count +
                ", windowStart=" + new Timestamp(windowStart) +
                ", windowEnd=" + new Timestamp(windowEnd) +
                '}';
    }
}
